﻿#region File Description
///////////////////////////////////////////////////////////////////////////////
/// \file Entity.cs
/// \brief This file stores the Entity class
/// \note This should be sublclassed in application to provide loading and saving functionality
/// \author Bradley Mclain
/// \date 15/5/2010
/// \remarks Copyright(c) 2010 LM01 Project Group (Animus Games - ViralFlux)
/// \remarks Some Rights Reserved.
/// Licenced under: Microsoft Reciprocal License (Ms-RL)
/// For More Information see: www.microsoft.com/opensource/licenses.mspx
///////////////////////////////////////////////////////////////////////////////
#endregion

namespace PropagationEngine
{
    /// <summary>
    /// \class Entity
    /// \brief This class represents an entity that moves through Ecosystem
    /// \note It should be subclassed in application
    /// \author Bradley Mclain
    /// \date 15/5/2010
    /// </summary>
    public class Entity
    {
        #region Properties

        public uint ID { get; private set; }
        public int Power { get; private set; }
        public int Type { get; private set; }
        public int MaxCount { get; private set; } //measure max infected nodes
        public int Count
        {
            get { return this.count; }
            set
            {
                this.count = value;
                if (count > MaxCount)
                    MaxCount = count;
            }

        }
        private int count;

        #endregion

        #region Methods

        /// <summary>
        /// \brief Constructor for Entity
        /// \note It should be subclassed in application
        /// \param id The unique ID for an entity
        /// \param power A generic representation of power, used to see which entities can overpower another
        /// \param type Defines the type of entity, used to narrow down ruleset, or applying rules
        /// \author Bradley Mclain
        /// \date 15/5/2010
        /// </summary>
        public Entity(uint id, int power, int type)
        {
            ID = id;
            Power = power;
            Type = type;
            MaxCount = 0;
            count = 0;
        }

        #endregion

    }
}
